package IViews;

import java.awt.Image;

import javax.swing.Icon;
import javax.swing.ImageIcon;
import javax.swing.JLabel;

class IImageWraper extends JLabel {
	
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	
	private String myImg = "";
	
	public IImageWraper(int x, int y, int width, int height, String img) {
		this.setBounds(x, y, width, height);
		this.myImg = img;
		this.setIcon(IViewConsts.loadImageAndResize(img, width, height));
	}	
	
	public void changeMyImageIcon(int width, int height){
		this.setSize(width, height);
		this.setIcon(IViewConsts.loadImageAndResize(myImg, width, height));
	}
}
